#!/usr/bin/env python

class TREE:
    def __init__(self, raw):
        self.id = raw[0]
        self.addr = raw[1]
        self.type = raw[2]
        self.op0 = raw[3]
        self.op1 = raw[4]
        self.op2 = raw[5]
        if raw[6] == 'NULL':
            self.name = None
        else:
            self.name = raw[6]
        self.num = raw[7]
        self.var = raw[8]
        if raw[9] == 'NULL':
            self.value = None
        else:
            self.value = raw[9]

